li = [1,2,3]
print(li)
print(li,type(li))

li = [1,"ping pong",False,[1,2,3]]
print(li)
print(li,type(li))

li = [1,2,3]
print(li[0])
print(li[1])
print(li[-1])
print(li[-2])

li = [1,2,3,4,5,6,7,8,9]
print('index从1开始，到3:',li[1:3])
print('index从2开始直到结束：',li[2:])
print('步长为2：',li[::2])
print('正向切片,索引下标从1到4，步长为2：',li[1:4:2])
print('反向切片,索引下标从1到4，步长为2：',li[-1:-4:-2])
